/* CSS 变量定义 */
:root {
  --primary-color: #4f46e5;
  --primary-light: #6366f1;
  --secondary-color: #8b5cf6;
  --accent-color: #ec4899;
  --success-color: #10b981;
  --warning-color: #f59e0b;
  --error-color: #ef4444;
  --background-color: #f9fafb;
  --surface-color: #ffffff;
  --text-primary: #111827;
  --text-secondary: #4b5563;
  --text-tertiary: #9ca3af;
  --border-color: #e5e7eb;
  --border-light: #f3f4f6;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --border-radius: 12px;
  --border-radius-sm: 8px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: all 0.2s ease;
}

/* 基础样式重置 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
    'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--background-color);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* 容器样式 */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

footer a{
  color: var(--surface-color);
  text-decoration: none;
}

/* 英雄区域 */
.hero-section {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  color: white;
  padding: 120px 0;
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 10% 20%, rgba(255, 255, 255, 0.1) 0%, transparent 20%),
              radial-gradient(circle at 90% 80%, rgba(255, 255, 255, 0.1) 0%, transparent 20%);
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 800;
  margin-bottom: 20px;
  line-height: 1.2;
  background: linear-gradient(45deg, #ffffff, #e0e7ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.5rem;
  margin-bottom: 40px;
  opacity: 0.95;
  font-weight: 300;
}

.hero-cta {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

/* 按钮样式 */
.btn-primary,
.btn-secondary,
.btn-tertiary {
  padding: 16px 32px;
  border-radius: var(--border-radius);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: none;
  outline: none;
  min-width: 160px;
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  text-decoration: none;
  gap: 8px;
  letter-spacing: 0.02em;
  will-change: transform, box-shadow;
}

/* 按钮通用悬停效果 */
.btn-primary:hover,
.btn-secondary:hover,
.btn-tertiary:hover {
  transform: translateY(-2px);
}

/* 主按钮 - 实心强调按钮 */
.btn-primary {
  background: linear-gradient(135deg, #ffffff, #f0f4ff);
  color: var(--primary-color);
  box-shadow: var(--shadow-lg), 0 4px 16px rgba(79, 70, 229, 0.1);
}

.btn-primary:hover {
  box-shadow: var(--shadow-xl), 0 8px 24px rgba(79, 70, 229, 0.2);
}

.btn-primary:active {
  transform: translateY(0);
}

/* 主按钮发光效果 */
.btn-primary::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.btn-primary:hover::before {
  width: 300px;
  height: 300px;
}

/* 次要按钮 - 半透明玻璃态按钮 */
.btn-secondary {
  background: rgba(255, 255, 255, 0.15);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(12px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.25);
  border-color: rgba(255, 255, 255, 0.4);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

/* 次要按钮边框动画 */
.btn-secondary::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 1px solid transparent;
  border-radius: inherit;
  pointer-events: none;
  background: linear-gradient(90deg, rgba(255,255,255,0.4), transparent, rgba(255,255,255,0.4)) 0 0 / 200% 100%;
  animation: shimmer 3s infinite;
}

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* 第三级按钮 - 描边按钮 */
.btn-tertiary {
  background: transparent;
  color: white;
  border: 2px solid rgba(255, 255, 255, 0.4);
  backdrop-filter: blur(8px);
  transition: all 0.3s ease;
}

.btn-tertiary:hover {
  border-color: white;
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* 按钮聚焦状态 */
.btn-primary:focus,
.btn-secondary:focus,
.btn-tertiary:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(107, 114, 128, 0.1), var(--shadow-md);
}

/* 按钮加载状态（预留） */
.btn-primary.loading,
.btn-secondary.loading,
.btn-tertiary.loading {
  pointer-events: none;
  opacity: 0.7;
}

/* 响应式按钮调整 */
@media (max-width: 768px) {
  .btn-primary,
  .btn-secondary,
  .btn-tertiary {
    padding: 14px 24px;
    min-width: 140px;
    font-size: 0.95rem;
  }
}

/* 核心功能区域 */
.features-section {
  padding: 100px 0;
  background: var(--surface-color);
}

.section-title {
  text-align: center;
  margin-bottom: 12px;
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--text-primary);
}

.section-description {
  text-align: center;
  margin-bottom: 60px;
  font-size: 1.25rem;
  color: var(--text-secondary);
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.feature-card {
  background: var(--surface-color);
  border-radius: var(--border-radius);
  padding: 35px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  border: 1px solid var(--border-color);
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
  transform: scaleX(0);
  transform-origin: left;
  transition: var(--transition);
}

.feature-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary-light);
}

.feature-card:hover::before {
  transform: scaleX(1);
}

.feature-icon {
  font-size: 3rem;
  margin-bottom: 20px;
  color: var(--primary-color);
}

.feature-card h3 {
  margin-bottom: 15px;
  font-size: 1.5rem;
  color: var(--text-primary);
  font-weight: 600;
}

.feature-card p {
  color: var(--text-secondary);
  font-size: 1rem;
  line-height: 1.6;
}

/* 图表演示区域 */
.demo-section {
  padding: 100px 0;
  background: var(--background-color);
}

/* 标签导航组件样式 */
.tabs-navigation {
  display: flex;
  align-items: center;
  margin-bottom: 1rem;
  position: relative;
}

.tab-nav-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid #e0e0e0;
  background: white;
  color: #667eea;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  z-index: 10;
  opacity: 0;
  pointer-events: none;
  position: absolute;
}

.tab-nav-btn.visible {
  opacity: 1;
  pointer-events: all;
}

.tab-nav-btn:hover:not(:disabled) {
  background-color: #f5f5f5;
  transform: scale(1.05);
}

.tab-nav-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  background-color: #f9f9f9;
}

.tab-nav-btn.active {
  background-color: #667eea;
  color: white;
  border-color: #667eea;
}

#left-nav-btn {
  left: -60px;
}

#right-nav-btn {
  right: -60px;
}

.tabs-container {
  flex: 1;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  scroll-behavior: smooth;
  width: 100%;
  padding: 5px 0;
}

.tabs-container::-webkit-scrollbar {
  display: none;
}

/* 图表标签容器样式 */
.chart-tabs {
  display: flex;
  gap: 1rem;
}

/* 标签按钮样式 */
.tab-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--surface-color);
  border: 1px solid var(--border-color);
  padding: 12px 20px;
  border-radius: var(--border-radius-sm);
  cursor: pointer;
  transition: var(--transition);
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-secondary);
  white-space: nowrap;
  min-width: 120px;
  justify-content: center;
}

.tab-icon {
  width: 20px;
  height: 20px;
  display: block;
}

.tab-btn:hover {
  background: var(--primary-light);
  color: white;
  border-color: var(--primary-light);
  transform: translateY(-1px);
}

.tab-btn.active {
  background: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
  box-shadow: var(--shadow-md);
}

/* 图表展示容器样式 */
.chart-display-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 30px;
}

.code-panel, .preview-panel {
  background: var(--surface-color);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 500px;
}

.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 20px;
  background: var(--background-color);
  border-bottom: 1px solid var(--border-color);
}

.panel-header h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
}

.zoom-controls {
  display: flex;
  gap: 0.5rem;
}

/* 通用按钮样式 */
.copy-button, .zoom-button, .close-button, .edit-button {
  width: 32px;
  height: 32px;
  border-radius: 4px;
  border: none;
  background: #f5f5f5;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.copy-button:hover, .zoom-button:hover, .close-button:hover, .edit-button:hover {
  background: #e0e0e0;
}

.copy-button.copied {
  background-color: #4caf50;
  color: white;
}

/* 编辑器按钮样式 */
.editor-btn {
  background-color: #4caf50;
}

.editor-btn:hover {
  background-color: #43a047;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(76, 175, 80, 0.3);
}

/* 代码区域样式 */
.code-content-wrapper {
  flex: 1;
  overflow: hidden;
  position: relative;
}

.code-content {
  padding: 20px;
  font-family: 'Fira Code', 'Courier New', monospace;
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--text-primary);
  background: #f8fafc;
  border: none;
  border-radius: 0;
  overflow-x: auto;
  overflow-y: auto;
  height: 100%;
  width: 100%;
  white-space: pre-wrap;
  word-wrap: break-word;
  resize: none;
  outline: none;
  transition: border-color var(--transition-fast);
}

.code-highlight {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  padding: 20px;
  font-family: 'Fira Code', 'Courier New', monospace;
  font-size: 0.9rem;
  line-height: 1.5;
  white-space: pre-wrap;
  word-wrap: break-word;
  overflow: auto;
  z-index: 1;
  pointer-events: none;
  background-color: transparent;
  border: none;
  color: transparent;
}

.code-highlight code {
  background: transparent !important;
  padding: 0 !important;
  margin: 0 !important;
}

.chart-preview-container {
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  background-color: #ffffff;
  padding: 20px;
  min-height: 400px;
}

/* 预览面板特殊设置 */
.preview-panel {
  height: 440px;
}

.preview-panel.fullscreen {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80vw;
  height: 60vh;
  z-index: 1000;
}

.preview-panel.fullscreen #close-btn {
  display: inline-flex;
}

/* 缩放控制按钮样式 */
.zoom-button {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface-color);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  width: 32px;
  height: 32px;
  border-radius: var(--border-radius-sm);
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 500;
  transition: var(--transition);
}

.zoom-button:hover {
  background: var(--primary-light);
  color: white;
  border-color: var(--primary-light);
  transform: translateY(-1px);
}

/* 关闭按钮样式 - 默认隐藏，全屏模式时显示 */
#close-btn {
  display: none;
  background: var(--surface-color);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-sm);
  padding: 6px 8px;
  cursor: pointer;
  transition: var(--transition);
  flex-shrink: 0;
}

#close-btn:hover {
  background: var(--error-color);
  color: white;
  border-color: var(--error-color);
}

/* 全屏模式时显示关闭按钮 - 使用更直接的选择器 */
#chart-preview.fullscreen-active {
  width: 60vw;
  height: 60vh;
}

/* 预览面板动画效果 */
.preview-panel {
  transition: all 0.3s ease-out;
}

/* 全屏模式时显示关闭按钮 - 使用更直接的选择器 */
#close-btn {
  display: none;
}

.preview-panel.fullscreen-active .panel-header .zoom-controls #close-btn {
  display: inline-flex;
}

/* 预览内容容器 */
.preview-content {
  position: relative;
  padding: 20px;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  background: #ffffff;
  overflow: auto;
  text-align: center;
}

#mermaid-preview {
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: visible;
  background-color: #ffffff;
  border-radius: var(--border-radius-sm);
  padding: 20px;
  transition: all var(--transition-fast);
  min-height: 400px;
}

#mermaid-preview > div {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

#mermaid-preview svg {
  max-width: 100%;
  height: auto;
  width: auto;
  display: block;
  transition: transform 0.3s ease;
  margin: 0 auto;
}

#mermaid-preview.error {
  background-color: #fef2f2;
  border-color: var(--error-color);
}

.error-message {
  color: var(--error-color);
  text-align: center;
  padding: 20px;
  font-size: 16px;
  line-height: 1.4;
  font-family: 'Inter', sans-serif;
}

.svg-preview-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: var(--border-radius-sm);
  box-shadow: var(--shadow-sm);
  display: block;
  margin: 0 auto;
}

/* 模态窗口样式 */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.8);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal-content {
  background-color: var(--surface-color);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-xl);
  position: relative;
  width: 60vw;
  height: 60vh;
  max-width: 1200px;
  max-height: 800px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.modal-close-btn {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: rgba(0, 0, 0, 0.1);
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: all var(--transition-fast);
  z-index: 10;
}

.modal-close-btn:hover {
  background-color: var(--error-color);
  color: white;
  transform: rotate(90deg);
}

.modal-image-container {
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

.modal-svg-wrapper {
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

.modal-svg-wrapper svg {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
}

/* 全屏预览关闭按钮样式 - 放置在最右侧 */
#close-fullscreen-btn {
  position: absolute;
  top: 15px;
  right: 15px;
  background-color: rgba(0, 0, 0, 0.5);
  color: white;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 1002;
  flex-shrink: 0;
}

#close-fullscreen-btn:hover {
  background-color: rgba(0, 0, 0, 0.7);
  transform: scale(1.1);
}

#close-fullscreen-btn svg {
  width: 20px;
  height: 20px;
}

/* 页脚样式 */
.footer-section {
  background: var(--text-primary);
  color: white;
  padding: 80px 0 40px;
}

.footer-content {
  display: grid;
  grid-template-columns: 1fr 3fr;
  gap: 60px;
  margin-bottom: 60px;
}

.footer-logo h2 {
  font-size: 1.8rem;
  margin-bottom: 10px;
  font-weight: 700;
}

.footer-logo p {
  color: var(--text-tertiary);
  font-size: 1rem;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 40px;
}

.footer-column h4 {
  font-size: 1.1rem;
  margin-bottom: 20px;
  font-weight: 600;
}

.footer-column ul {
  list-style: none;
}

.footer-column li {
  margin-bottom: 12px;
}

.footer-column a {
  color: var(--text-tertiary);
  text-decoration: none;
  transition: var(--transition-fast);
  font-size: 0.95rem;
}

.footer-column a:hover {
  color: white;
  padding-left: 5px;
}

.footer-bottom {
  padding-top: 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
}

.footer-bottom p {
  color: var(--text-tertiary);
  font-size: 0.9rem;
}

/* 错误提示样式 */
.chart-error {
  text-align: center;
  padding: 40px;
  color: #e74c3c;
  background-color: #fadbd8;
  border-radius: 8px;
  font-weight: 500;
}

/* 代码高亮样式 */
.code-highlight {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 20px;
  font-family: 'Fira Code', 'Courier New', monospace;
  font-size: 0.9rem;
  line-height: 1.5;
  white-space: pre-wrap;
  word-wrap: break-word;
  overflow: auto;
  z-index: 1;
  pointer-events: none;
  background-color: transparent;
  border: none;
}

/* highlight.js 主题样式 */
.hljs {
  background: transparent !important;
}

/* graph TD 等图表类型 - 红色显示 */
.hljs-keyword {
  color: #dc2626 !important; /* 更鲜艳的红色 */
  font-weight: 700;
}

/* title, section 等关键字 - 蓝色显示 */
.hljs-built_in {
  color: #2563eb !important; /* 更鲜艳的蓝色 */
  font-weight: 600;
}

/* 注释 - 灰色显示 */
.hljs-comment {
  color: #6b7280 !important;
  font-style: italic;
  font-weight: 400;
}

.hljs-type {
  color: #7c3aed !important; /* 紫色 */
  font-weight: 600;
}

.hljs-string {
  color: #065f46 !important; /* 深绿色 */
}

.hljs-number {
  color: #2563eb !important; /* 蓝色 */
}

.hljs-operator {
  color: #dc2626 !important; /* 红色 */
}

.hljs-attribute {
  color: #16a34a !important; /* 绿色 */
}

.hljs-tag {
  color: #16a34a !important; /* 绿色 */
}

.hljs-meta {
  color: #7c3aed !important; /* 紫色 */
}

.hljs-variable {
  color: #ea580c !important; /* 橙色 */
}

.hljs-title {
  color: #7c3aed !important; /* 紫色 */
  font-weight: 600;
}

/* 基础语法高亮样式（降级方案） */
/* graph TD 等图表类型 - 红色显示 */
.keyword {
  color: #dc2626;
  font-weight: 700;
}

/* title, section 等关键字 - 蓝色显示 */
.built_in {
  color: #2563eb;
  font-weight: 600;
}

/* 注释 - 灰色显示 */
.comment {
  color: #6b7280;
  font-style: italic;
  font-weight: 400;
}

.type {
  color: #7c3aed;
  font-weight: 600;
}

.direction {
  color: #2563eb;
  font-weight: 600;
}

.shape {
  color: #ea580c;
}

.color {
  color: #16a34a;
}

.number {
  color: #2563eb;
}

.string {
  color: #065f46;
}

.operator {
  color: #dc2626;
}

/* 代码高亮容器样式优化 */
.code-content-wrapper {
  position: relative;
}

.code-content {
  position: relative;
  z-index: 2;
  background: #f8fafc !important;
  color: #111827 !important;
  caret-color: #111827;
}

.code-highlight code {
  background: transparent !important;
  padding: 0 !important;
  margin: 0 !important;
}

/* 滚动同步优化 */
.code-content::-webkit-scrollbar,
.code-highlight::-webkit-scrollbar {
  width: 8px;
}

.code-content::-webkit-scrollbar-track,
.code-highlight::-webkit-scrollbar-track {
  background: #f1f5f9;
  border-radius: 4px;
}

.code-content::-webkit-scrollbar-thumb,
.code-highlight::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}

.code-content::-webkit-scrollbar-thumb:hover,
.code-highlight::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* 响应式设计 */
@media (max-width: 1200px) {
  .hero-title {
    font-size: 3rem;
  }
  
  .chart-display-container {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  
  .code-panel,
  .preview-panel {
    min-height: 400px;
  }
}

@media (max-width: 992px) {
  .hero-section {
    padding: 100px 0;
  }
  
  .hero-title {
    font-size: 2.8rem;
  }
  
  .features-section,
  .demo-section {
    padding: 80px 0;
  }
  
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .footer-content {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

@media (max-width: 768px) {
  .hero-section {
    padding: 80px 0;
  }
  
  .hero-title {
    font-size: 2.4rem;
  }
  
  .hero-subtitle {
    font-size: 1.25rem;
  }
  
  .hero-cta {
    flex-direction: column;
    align-items: center;
  }
  
  .btn-primary,
  .btn-secondary {
    width: 100%;
    max-width: 300px;
  }
  
  .section-title {
    font-size: 2rem;
  }
  
  .features-grid {
    grid-template-columns: 1fr;
  }
  
  .tab-nav-btn {
    width: 40px;
    height: 40px;
  }
  
  .tab-nav-btn svg {
    width: 20px;
    height: 20px;
  }
  
  .tab-btn {
    padding: 10px 16px;
    font-size: 0.9rem;
    min-width: 100px;
  }
  
  .footer-links {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .chart-display-container {
    flex-direction: column;
  }
  
  .code-panel, .preview-panel {
    min-height: 300px;
  }
  
  .tabs-navigation {
    padding: 0 40px;
  }
  
  .tab-nav-btn {
    width: 35px;
    height: 35px;
  }
  
  .tabs-container {
    margin: 0 0.5rem;
  }
  
  .chart-tabs {
    gap: 0.5rem;
  }
  
  .tab-btn {
    min-width: 60px;
    padding: 0.75rem 0.5rem;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 16px;
  }
  
  .hero-section {
    padding: 60px 0;
  }
  
  .hero-title {
    font-size: 2rem;
  }
  
  .hero-subtitle {
    font-size: 1.1rem;
  }
  
  .features-section,
  .demo-section {
    padding: 60px 0;
  }
  
  .feature-card {
    padding: 25px;
  }
  
  .section-title {
    font-size: 1.8rem;
  }
  
  .panel-header {
    padding: 12px 16px;
  }
  
  .code-content,
  .preview-content {
    padding: 16px;
  }
  
  .footer-links {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  
  .footer-section {
    padding: 60px 0 30px;
  }
  
  .tabs-container {
    margin: 0 0.5rem;
  }
  
  .chart-tabs {
    gap: 0.5rem;
  }
  
  .tab-btn {
    min-width: 60px;
    padding: 0.75rem 0.5rem;
  }
}